package swu.edu.cn.javaee.mapper;

import org.springframework.stereotype.Repository;
import swu.edu.cn.javaee.entity.Collect;

import java.util.List;

@Repository
public interface CollectMapper {
    //文章、评论、商户、产品收藏
    public void articleCollect(Collect collect);
    public void reviewCollect(Collect collect);
    public void merchantCollect(Collect collect);
    public void productCollect(Collect collect);
    //查询文章、评论、商户、产品收藏
    public List<Collect> queryArticleList(String user_id);
    public List<Collect> queryReviewList(String user_id);
    public List<Collect> queryMerchantList(String user_id);
    public List<Collect> queryProductList(String user_id);
    //查询文章、评论、商户、产品收藏条数
    public Integer countArticle(String user_id);
    public Integer countReview(String user_id);
    public Integer countMerchant(String user_id);
    public Integer countProduct(String user_id);
    //删除文章、评论、商户、产品收藏
    public void deleteArticle(String user_id, String article_id);
    public void deleteReview(String user_id, String review_id);
    public void deleteMerchant(String user_id, String merchant_id);
    public void deleteProduct(String user_id, String product_id);
}
